Filter hook 'rest_{$this->post_type}_item_schema'
in WP Core File wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php at line 2658
Description
Filters the post's schema. The dynamic portion of the filter, `$this->post_type`, refers to the post type slug for the controller. Possible hook names include: - `rest_post_item_schema` - `rest_page_item_schema` - `rest_attachment_item_schema`
Occurrences
Filename |
Line Number |
wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php |
2658 |
Parameters
Type |
Name |
Description |
array |
$schema |
Item schema data. |
PHP Doc
/**
* Filters the post's schema.
*
* The dynamic portion of the filter, `$this->post_type`, refers to the
* post type slug for the controller.
*
* Possible hook names include:
*
* - `rest_post_item_schema`
* - `rest_page_item_schema`
* - `rest_attachment_item_schema`
*
* @since 5.4.0
*
* @param array $schema Item schema data.
*/